package sdk.webview.fmc.com.fmcsdk.bean;

import com.google.gson.annotations.SerializedName;

import java.util.List;

import sdk.webview.fmc.com.fmcsdk.base.BaseData;

/**
 * 权限模块bean类
 * Created by ydm on 2017/8/15.
 */

public class Auth extends BaseData {
    /**
     * page : -1
     * total : -1
     * records : [{"apps":[{"actions":"myapply_read","code":"myapply","desc":"我的申请","url":""},{"actions":"mymessage_read","code":"mymessage","desc":"我的消息","url":""}],"code":"my","desc":"我的","url":"my"},{"apps":[{"actions":"insporder_read","code":"insporder","desc":"巡检查询","url":"9"},{"actions":"pmorder_read","code":"pmorder","desc":"保养单查询","url":""},{"actions":"workorder_read","code":"workorder","desc":"服务单查询","url":""}],"code":"select","desc":"查询","url":"select"},{"apps":[{"actions":"inspmonitor_read","code":"inspmonitor","desc":"巡检监控","url":"10"},{"actions":"pmomonitor_read","code":"pmomonitor","desc":"保养监控","url":""},{"actions":"workmonitor_read","code":"workmonitor","desc":"服务单监控","url":""}],"code":"monitor","desc":"监控","url":"monitor"},{"apps":[{"actions":"timelyrpt_read","code":"timelyrpt","desc":"服务及时率","url":""},{"actions":"wohrsrpt_read","code":"wohrsrpt","desc":"工时统计","url":""},{"actions":"woserverpt_read","code":"woserverpt","desc":"客户满意度","url":""}],"code":"analyse","desc":"分析","url":"analyse"},{"apps":[{"actions":"addresslist_read","code":"addresslist","desc":"通讯录","url":""},{"actions":"jobschedule_read","code":"jobschedule","desc":"排班表","url":""},{"actions":"romotesup_read","code":"romotesup","desc":"远程专家支持","url":""},{"actions":"signrecord_read","code":"signrecord","desc":"签到记录","url":""}],"code":"addresslist","desc":"通讯录","url":"addresslist"},{"apps":[{"actions":"case_read","code":"case","desc":"随机资料与案例","url":""},{"actions":"learning_read","code":"learning","desc":"培训学习","url":""},{"actions":"solution_read","code":"solution","desc":"故障诊断与解决方法","url":""}],"code":"kb","desc":"知识库","url":"kb"}]
     */

    private int page;
    private int total;
    /**大模块集合*/
    private List<RecordsBean> records;

    public int getPage() {
        return page;
    }

    public void setPage(int page) {
        this.page = page;
    }

    public int getTotal() {
        return total;
    }

    public void setTotal(int total) {
        this.total = total;
    }

    public List<RecordsBean> getRecords() {
        return records;
    }

    public void setRecords(List<RecordsBean> records) {
        this.records = records;
    }

    public static class RecordsBean {
        /**
         * apps : [{"actions":"myapply_read","code":"myapply","desc":"我的申请","url":""},{"actions":"mymessage_read","code":"mymessage","desc":"我的消息","url":""}]
         * code : my
         * desc : 我的
         * url : my
         */

        @SerializedName("code")
        private String codeX;
        /**模块分类名称*/
        private String desc;
        private String url;
        /**子模块集合*/
        private List<AppsBean> apps;

        public String getCodeX() {
            return codeX;
        }

        public void setCodeX(String codeX) {
            this.codeX = codeX;
        }

        public String getDesc() {
            return desc;
        }

        public void setDesc(String desc) {
            this.desc = desc;
        }

        public String getUrl() {
            return url;
        }

        public void setUrl(String url) {
            this.url = url;
        }

        public List<AppsBean> getApps() {
            return apps;
        }

        public void setApps(List<AppsBean> apps) {
            this.apps = apps;
        }

        @Override
        public String toString() {
            return "RecordsBean{" +
                    "codeX='" + codeX + '\'' +
                    ", desc='" + desc + '\'' +
                    ", url='" + url + '\'' +
                    ", apps=" + apps +
                    '}';
        }

        public static class AppsBean {
            /**
             * actions : myapply_read
             * code : myapply
             * desc : 我的申请
             * url :
             */
            /**子分类英文名称*/
            private String actions;
            @SerializedName("code")
            private String codeX;
            /**子分类名称*/
            private String desc;
            /**子模块跳转的url*/
            private String url;
            /**子模块图片下载路径*/
            private String icon;
            /**测试数据*/
            private int urlImage;

            public int getUrlImage() {
                return urlImage;
            }

            public void setUrlImage(int urlImage) {
                this.urlImage = urlImage;
            }

            public String getActions() {
                return actions;
            }

            public void setActions(String actions) {
                this.actions = actions;
            }

            public String getCodeX() {
                return codeX;
            }

            public void setCodeX(String codeX) {
                this.codeX = codeX;
            }

            public String getDesc() {
                return desc;
            }

            public void setDesc(String desc) {
                this.desc = desc;
            }

            public String getUrl() {
                return url;
            }

            public void setUrl(String url) {
                this.url = url;
            }

            public String getIcon() {
                return icon;
            }

            public void setIcon(String icon) {
                this.icon = icon;
            }

            @Override
            public String toString() {
                return "AppsBean{" +
                        "actions='" + actions + '\'' +
                        ", codeX='" + codeX + '\'' +
                        ", desc='" + desc + '\'' +
                        ", url='" + url + '\'' +
                        ", icon='" + icon + '\'' +
                        ", urlImage=" + urlImage +
                        '}';
            }
        }
    }

    @Override
    public String toString() {
        return "Auth{" +
                "page=" + page +
                ", total=" + total +
                ", records=" + records +
                '}';
    }
}
